package com.redis.procuder;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Component;

/**
 * @Author: 胡成
 * @Version: 0.0.1V
 * @Date: 2018/10/26
 * @Description: 类描述
 **/
@Component
public class RedisService {

    @Autowired
    private StringRedisTemplate stringRedisTemplate;

    public void sendChannelMess(String topic, String message) {
        stringRedisTemplate.convertAndSend(topic, message);
    }

}
